home *** CD-ROM | disk | FTP | other *** search
/ Software of the Month Club 2000 October / Software of the Month - Ultimate Collection Shareware 277.iso / pc / PROGRAMS / UTILITY / WINLINUX / DATA1.CAB / programs_-_include / LINUX / FAT_CVF.H < prev    next >
C/C++ Source or Header  |  1999-09-17  |  2KB  |  50 lines

  1. #ifndef _FAT_CVF
  2. #define _FAT_CVF
  3.  
  4. #define CVF_USE_READPAGE  0x0001
  5.  
  6. struct cvf_format
  7. { int cvf_version;
  8.   char* cvf_version_text;
  9.   unsigned long flags;
  10.   int (*detect_cvf) (struct super_block*sb);
  11.   int (*mount_cvf) (struct super_block*sb,char*options);
  12.   int (*unmount_cvf) (struct super_block*sb);
  13.   struct buffer_head* (*cvf_bread) (struct super_block*sb,int block);
  14.   struct buffer_head* (*cvf_getblk) (struct super_block*sb,int block);
  15.   void (*cvf_brelse) (struct super_block *sb,struct buffer_head *bh);
  16.   void (*cvf_mark_buffer_dirty) (struct super_block *sb,
  17.                               struct buffer_head *bh,
  18.                               int dirty_val);
  19.   void (*cvf_set_uptodate) (struct super_block *sb,
  20.                          struct buffer_head *bh,
  21.                          int val);
  22.   int (*cvf_is_uptodate) (struct super_block *sb,struct buffer_head *bh);
  23.   void (*cvf_ll_rw_block) (struct super_block *sb,
  24.                         int opr,
  25.                         int nbreq,
  26.                         struct buffer_head *bh[32]);
  27.   int (*fat_access) (struct super_block *sb,int nr,int new_value);
  28.   int (*cvf_statfs) (struct super_block *sb,struct statfs *buf, int bufsiz);
  29.   int (*cvf_bmap) (struct inode *inode,int block);
  30.   int (*cvf_smap) (struct inode *inode,int sector);
  31.   ssize_t (*cvf_file_read) ( struct file *, char *, size_t, loff_t *);
  32.   ssize_t (*cvf_file_write) ( struct file *, const char *, size_t, loff_t *);
  33.   int (*cvf_mmap) (struct file *, struct vm_area_struct *);
  34.   int (*cvf_readpage) (struct inode *, struct page *);
  35.   int (*cvf_writepage) (struct inode *, struct page *);
  36.   int (*cvf_dir_ioctl) (struct inode * inode, struct file * filp,
  37.                         unsigned int cmd, unsigned long arg);
  38.   void (*zero_out_cluster) (struct inode*, int clusternr);
  39. };
  40.  
  41. int register_cvf_format(struct cvf_format*cvf_format);
  42. int unregister_cvf_format(struct cvf_format*cvf_format);
  43. void dec_cvf_format_use_count_by_version(int version);
  44. int detect_cvf(struct super_block*sb,char*force);
  45.  
  46. extern struct cvf_format *cvf_formats[];
  47. extern int cvf_format_use_count[];
  48.  
  49. #endif
  50.